package com.xw.strategy;

import java.util.Arrays;

/**
 * @author: xw
 * @create: 2022/9/14 14:26
 * @description:
 */
public class Main {
    public static void main(String[] args) {
//        Cat[] a = {new Cat(3, 5), new Cat(5, 1), new Cat(1, 3)};
//        Dog[] a = {new Dog(5),new Dog(1),new Dog(9)};
        Sort sort = new Sort();
        CatHeightComparator catHeightComparator = new CatHeightComparator();
        CatWeightComparator catWeightComparator = new CatWeightComparator();

        Tiger[] a = {new Tiger(100),new Tiger(1),new Tiger(45),new Tiger(89)};
        TigerComparator tigerComparator = new TigerComparator();
        sort.sort(a,tigerComparator);
        System.out.println(Arrays.toString(a));
    }
}
